package cn.stylefeng.guns.modular.order.service;

import cn.stylefeng.guns.base.pojo.page.LayuiPageInfo;
import cn.stylefeng.guns.modular.order.entity.OrderWeightCheck;
import cn.stylefeng.guns.modular.order.model.params.OrderWeightCheckParam;
import cn.stylefeng.guns.modular.order.model.result.OrderWeightCheckResult;
import cn.stylefeng.roses.core.reqres.response.ResponseData;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

/**
 * <p>
 * 订单重量复核 服务类
 * </p>
 *
 * @author zhangzh
 * @since 2024-05-20
 */
public interface OrderWeightCheckService extends IService<OrderWeightCheck> {

    /**
     * 新增
     *
     * @author zhangzh
     * @Date 2024-05-20
     */
    void add(OrderWeightCheckParam param);

    /**
     * 删除
     *
     * @author zhangzh
     * @Date 2024-05-20
     */
    void delete(OrderWeightCheckParam param);

    /**
     * 更新
     *
     * @author zhangzh
     * @Date 2024-05-20
     */
    void update(OrderWeightCheckParam param);

    /**
     * 查询单条数据，Specification模式
     *
     * @author zhangzh
     * @Date 2024-05-20
     */
    OrderWeightCheckResult findBySpec(OrderWeightCheckParam param);

    /**
     * 查询列表，Specification模式
     *
     * @author zhangzh
     * @Date 2024-05-20
     */
    List<OrderWeightCheckResult> findListBySpec(OrderWeightCheckParam param);

    /**
     * 查询分页数据，Specification模式
     *
     * @author zhangzh
     * @Date 2024-05-20
     */
     LayuiPageInfo findPageBySpec(OrderWeightCheckParam param, String condition);



    /**
     * 数据导入
     * @param file
     * @param orderWeightCheckParam
     * @param data
     * @return
     * @throws Exception
     */
    ResponseData getExceldata(MultipartFile file, OrderWeightCheckParam orderWeightCheckParam, ResponseData data) throws Exception;


    /**
     * 根据订单号 修改复核重量
     * @param orderWeightCheckParam
     * @return
     */
    ResponseData updateCheckWeightByOrderNo(OrderWeightCheckParam orderWeightCheckParam);

}
